1. Field of the Invention
The present invention relates to a task allocation time decision apparatus which is used in a software development device and a method thereof. The task allocation time decision apparatus previously computes a task execution time for enabling scheduling on a processor at a time of scheduling a group of given cyclic tasks by a designated scheduling method.
2. Discussion of the Related Art
An embedded system requires precision of results and time constraint. Under such time constraint, each of tasks given to the system must complete its designated processing until the fixed time. The time which should be observed is referred to as deadline. It is important task to schedule such that the deadline of each task is kept when the tasks are executed in parallel. A scheduling with such time constraint is referred to as real time scheduling.
There has been provided an RM (Rate Monotonic) method and an EDF (Earliest Deadline First) method as a representative real time scheduling method. In the RM method, for a group of tasks that are cyclically activated, the shorter period each of them has, the higher priority is set. In the EDF method, the shorter a difference between the deadline and a current time is, the higher the priority is set.
A method of determining whether or not the scheduling is possible so as to keep the deadline at a time of applying a certain scheduling method to a given group of tasks is referred to as decision of ability of scheduling. The decision of ability of scheduling is an important technique in utilizing the real time scheduling at a time of structuring a system.
The longest time from when a task starts to be executed to when the task ends is referred to as worst execution time. Especially in the RM method, it is possible to decide whether or not the scheduling is possible upon the group of tasks by providing a period and the worst execution time of each of tasks.
FIG. 1 shows a conventional scheduling decision device which adopts the above-described method of deciding the ability of scheduling. The scheduling decision device has a task context memory unit 10, a scheduling decision unit 20 and a decision result display unit 30. The task context memory unit 10 stores the information of each of tasks with a group of task programs 11 formed in advance and an execution period 12 of each of the tasks being as an input.
Firstly, a task developer forms a group of tasks in advance, and inputs the group of tasks and the generation period of each of the tasks to the scheduling decision device. An execution time evaluation unit 21 evaluates a worst execution time of each of the tasks. Then, a scheduling evaluation unit 22 decides, on a basis of the worst execution time and the execution period of each of the tasks, whether the scheduling is possible with the designated scheduling method. The decision result display unit 30 informs the task developer of the results of decision.
When the scheduling decision unit 20 decides that the scheduling is impossible, the task developer corrects the group of tasks and optimizes the same, and then the decision is made again at the scheduling decision device. The task developer repeats the above-described process until the scheduling is possible.
When the above-described scheduling decision device is used, the task developer must form in advance a group of tasks and repeat correction and optimization of the tasks, evaluation of the worst execution time and decision of the ability of scheduling until the scheduling is possible. Consequently, in such scheduling decision method, a number of steps is assumed to be increased and whether or not the scheduling is possible cannot be known in an early period of time. Further, according to this scheduling decision method, since a target execution time is not provided at a time of forming tasks and correcting the same, it is difficult for a task developer to decide a method of structuring the tasks or a method of optimizing the same.